﻿<%@ Page Title="" MasterPageFile="~/BackOffice.master" Language="C#" AutoEventWireup="true" CodeBehind="CadastroClientePJ.aspx.cs" Inherits="MakeIT.Deo.Apresentacao.CadastroClientePJ" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>

<%@ Register Assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"
    Namespace="System.Web.UI" TagPrefix="asp" %>


<asp:Content ID="cMain" ContentPlaceHolderID="cphMain" runat="server">
    <div class="art-Block">
        <div class="art-Block-body">
            <div class="art-BlockHeader">
                <div class="l"></div>
                <div class="r"></div>
                <div class="art-header-tag-icon">
                    <div class="t">Cadastro de Cliente - Pessoa Jur&iacute;dica</div>
                </div>
            </div>
            <div class="art-BlockContent">
                <div class="art-BlockContent-tl"></div>
                <div class="art-BlockContent-tr"></div>
                <div class="art-BlockContent-bl"></div>
                <div class="art-BlockContent-br"></div>
                <div class="art-BlockContent-tc"></div>
                <div class="art-BlockContent-bc"></div>
                <div class="art-BlockContent-cl"></div>
                <div class="art-BlockContent-cr"></div>
                <div class="art-BlockContent-cc"></div>
                <div class="art-BlockContent-body">

    <asp:UpdatePanel ID="upnCliente" runat="server">
        <ContentTemplate>
            <asp:TabContainer ID="tabCliente" runat="server" ActiveTabIndex="1">
                <asp:TabPanel ID="tabPesquisa" runat="server" HeaderText="Pesquisa">
                    <ContentTemplate>
                        <div style="width: 100%;">
                            <table style="width: 575px;">
                                <tr>
                                    <td>
                                        C&oacute;digo
                                    </td>
                                    <td>
                                        <asp:TextBox ID="txtId" runat="server"></asp:TextBox>
                                        <asp:MaskedEditExtender ID="mskTxtId" runat="server" Mask="9999999" TargetControlID="txtId" PromptCharacter="" />
                                    </td>
                                    <td>
                                        Nome
                                    </td>
                                    <td>
                                        <asp:TextBox ID="txtNome" runat="server"></asp:TextBox>
                                    </td>
                                </tr>
                                <tr>
                                    <td colspan="4">
                                        <asp:Button ID="btnPesquisa" runat="server" Text="Pesquisa" OnClick="btnPesquisa_Click" />
                                        <br />
                                        <br />
                                    </td>
                                </tr>
                                <tr>
                                    <td colspan="4">
                                    <asp:GridView ID="grvResultado" runat="server" AutoGenerateColumns="False" EmptyDataText="N&atilde;o foram encontrados registros nessa pesquisa!">
                                            <Columns>
                                                <asp:TemplateField>
                                                    <ItemTemplate>
                                                        <asp:ImageButton ID="imgbVisualizar" runat="server" OnClick="imgbVisualizar_Click"
                                                            ImageUrl="~/App_Themes/Padrao/imagens/backoffice/editar.gif" CommandArgument='<%#Eval("IdCliente") %>' />
                                                    </ItemTemplate>
                                                    <ItemStyle HorizontalAlign="Center" />
                                                </asp:TemplateField>
                                                <asp:BoundField DataField="IdCliente" HeaderText="ID"/>
                                                <asp:BoundField DataField="NomePJ" HeaderText="Nome" />
                                                <asp:BoundField DataField="CNPJ" HeaderText="CNPJ" />
                                                <asp:CheckBoxField DataField="Ativo" HeaderText="Ativo?" />
                                            </Columns>
                                        </asp:GridView>
                                    </td>
                                </tr>
                            </table>
                        </div>
                    </ContentTemplate>
                </asp:TabPanel>
                <asp:TabPanel ID="tabCadastro" runat="server" HeaderText="Cadastro">
                    <ContentTemplate>
                        <asp:Panel ID="panelCad" runat="server">
                            <div style="width: 100%;">
                                <table style="width: 575px;">
                                    <tr>
                                        <td>
                                            C&oacute;digo:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="txtCadId" runat="server" Enabled="False" BackColor="#E0E0E0"></asp:TextBox>
                                       </td>
                                    </tr>
                                    <tr>
                                        <td colspan="4" style="border-bottom:solid 1px gray;">
                                            <b>Contato</b>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Nome:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbNomePJ" runat="server"  MaxLength="20" Columns="20" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender1PJ" runat="server" TargetControlID="tbNomePJ" WatermarkText="Seu nome" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbNomePJ" 
                                               ErrorMessage="Favor informar o nome." ID="rfvTextBoxNomePJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender1PJ" runat="server" TargetControlID="rfvTextBoxNomePJ"></asp:ValidatorCalloutExtender>
                                        </td>
                                        <td>
                                            Sobrenome:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbSobrenomePJ" runat="server"  MaxLength="20" Columns="20" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender8PJ" runat="server" TargetControlID="tbSobrenomePJ" WatermarkText="Seu sobrenome" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbSobrenomePJ" 
                                               ErrorMessage="Favor informar o nome." ID="rfvTbSobrenomePJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender11PJ" runat="server" TargetControlID="rfvTbSobrenomePJ"></asp:ValidatorCalloutExtender>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Nascimento:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbNascimentoPJ" runat="server" Columns="10" ToolTip="Clique no calendário ao lado para informar sua data de nascimento."></asp:TextBox>
                                            <asp:ImageButton ID="imgTbNascimentoPJ" runat="server" ImageUrl="~/App_Themes/Padrao/Imagens/backoffice/Calendario.png" />
                                            <asp:MaskedEditExtender ID="MaskedEditExtender7" runat="server" 
                                                ClearTextOnInvalid="True" ErrorTooltipEnabled="true" AutoComplete="False"
                                                ClearMaskOnLostFocus="true" 
                                                InputDirection="LeftToRight" Mask="99/99/9999" MaskType="Date" 
                                                PromptCharacter="_" TargetControlID="tbNascimentoPJ" />
                                             <asp:RequiredFieldValidator ID="rfvTbNascimentoPJ" runat="server" ControlToValidate="tbNascimentoPJ" Display="None"
                                                ErrorMessage="Favor informar sua data de nascimento clicando no calendário ao lado." ValidationGroup="Salvar" />
                                            <asp:CalendarExtender ID="tbNascimento_CalendarExtenderPJ" runat="server" DaysModeTitleFormat="dd/MM/yyyy"
                                                Enabled="True" TargetControlID="tbNascimentoPJ" BehaviorID="imgTbNascimentoPJ"
                                                PopupButtonID="imgTbNascimentoPJ" Format="dd/MM/yyyy" TodaysDateFormat="dd/MM/yyyy">
                                            </asp:CalendarExtender>
                                             <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender12PJ" runat="server" TargetControlID="rfvTbNascimentoPJ" PopupPosition="Left"></asp:ValidatorCalloutExtender>
                                       </td>
                                        <td>
                                            Sexo:
                                        </td>
                                        <td>
                                            <asp:RadioButtonList ID="rblSexoPJ" runat="server" RepeatDirection="Horizontal">
                                                <asp:ListItem Text="Masculino" Value="Masculino"></asp:ListItem>
                                                <asp:ListItem Text="Feminino" Value="Feminino"></asp:ListItem>
                                            </asp:RadioButtonList>
                                            <asp:RequiredFieldValidator ControlToValidate="rblSexoPJ" 
                                               ErrorMessage="Favor informar o sexo." ID="rfvRblSexoPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" />
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender10PJ" runat="server" TargetControlID="rfvRblSexoPJ"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Email:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbMailPJ" runat="server" MaxLength="45" Columns="44"></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender2PJ" runat="server" TargetControlID="tbMailPJ" WatermarkText="Seu email para contato" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbMailPJ" 
                                               ErrorMessage="Favor informar o email." ID="rfvTbMailPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                           <asp:RegularExpressionValidator id="regEmailPJ" ControlToValidate="tbMailPJ"
                                                ErrorMessage="Email não informado corretamente."
                                                ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*"
                                                Runat="server" Display="None" ValidationGroup="Salvar"/> 
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender3PJ" runat="server" TargetControlID="rfvTbMailPJ"></asp:ValidatorCalloutExtender>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender2PJ" runat="server" TargetControlID="regEmailPJ"></asp:ValidatorCalloutExtender>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            CPF:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbCPFPJ" runat="server" MaxLength="15" Columns="20"></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender15PJ" runat="server" TargetControlID="tbCPFPJ" WatermarkText="Seu CPF" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:MaskedEditExtender ID="MaskedEditExtender2PJ" runat="server" 
                                                ClearTextOnInvalid="True" ErrorTooltipEnabled="true" AutoComplete="False"
                                                ClearMaskOnLostFocus="true" 
                                                InputDirection="LeftToRight" Mask="999.999.999-99" MaskType="None" 
                                                PromptCharacter="_" TargetControlID="tbCPFPJ" >
                                            </asp:MaskedEditExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbCPFPJ" 
                                               ErrorMessage="Favor informar o cpf." ID="rfvTbCPFPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender18PJ" runat="server" TargetControlID="rfvTbCPFPJ"></asp:ValidatorCalloutExtender>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Celular:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbCelPJ" runat="server" MaxLength="15" Columns="44"></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender17PJ" runat="server" TargetControlID="tbCelPJ" WatermarkText="Seu celular para contato" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:MaskedEditExtender ID="MaskedEditExtender4PJ" runat="server" 
                                                ClearTextOnInvalid="True" ErrorTooltipEnabled="true" AutoComplete="False"
                                                ClearMaskOnLostFocus="true" 
                                                InputDirection="LeftToRight" Mask="(99) 999999999" MaskType="None" 
                                                PromptCharacter="_" TargetControlID="tbCelPJ" >
                                            </asp:MaskedEditExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbCelPJ" 
                                               ErrorMessage="Favor informar o n&uacute;mero de telefone." ID="rfvTbCelPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender20PJ" runat="server" TargetControlID="rfvTbCelPJ"></asp:ValidatorCalloutExtender>
                                        </td>
                                    </tr>

                                    <tr>
                                        <td colspan="4" style="border-bottom:solid 1px gray;">
                                            <b>Empresa</b>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Nome Empresa:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbEmpresa" runat="server"  MaxLength="70" Columns="70" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender18" runat="server" TargetControlID="tbEmpresa" WatermarkText="Nome da Empresa" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbEmpresa" 
                                               ErrorMessage="Favor informar o nome de sua empresa." ID="rfvTbEmpresa" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender23" runat="server" TargetControlID="rfvTbEmpresa"></asp:ValidatorCalloutExtender>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            CNPJ:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbCNPJ" runat="server" MaxLength="18" Columns="20"></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender19" runat="server" TargetControlID="tbCNPJ" WatermarkText="CNPJ da empresa" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:MaskedEditExtender ID="MaskedEditExtender5" runat="server" 
                                                ClearTextOnInvalid="True" ErrorTooltipEnabled="true" AutoComplete="False"
                                                ClearMaskOnLostFocus="true" 
                                                InputDirection="LeftToRight" Mask="99.999.999/9999-99" MaskType="None" 
                                                PromptCharacter="_" TargetControlID="tbCNPJ" >
                                            </asp:MaskedEditExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbCNPJ" 
                                               ErrorMessage="Favor informar o CNPJ da empresa." ID="rfvTbCNPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender24" runat="server" TargetControlID="rfvTbCNPJ"></asp:ValidatorCalloutExtender>
                                        </td>
                                    </tr>

                                    <tr>
                                        <td>
                                            Endere&ccedil;o:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbEndPJ" runat="server"  MaxLength="100" Columns="80" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender9PJ" runat="server" TargetControlID="tbEndPJ" WatermarkText="Seu endereço" WatermarkCssClass="waterMark"/>
                                            <asp:RequiredFieldValidator ControlToValidate="tbEndPJ" 
                                               ErrorMessage="Favor informar o endereço." ID="rfvTbEndPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender13PJ" runat="server" TargetControlID="rfvTbEndPJ"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            N&uacute;mero:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbNumeroPJ" runat="server"  MaxLength="10" Columns="15" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender10PJ" runat="server" TargetControlID="tbNumeroPJ" WatermarkText="Número do endereço" WatermarkCssClass="waterMark"/>
                                            <asp:RequiredFieldValidator ControlToValidate="tbNumeroPJ" 
                                               ErrorMessage="Favor informar o número do endereço." ID="rfvTbNumeroPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender14PJ" runat="server" TargetControlID="rfvTbNumeroPJ"/>
                                        </td>
                                        <td>
                                            Complemento:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbComplPJ" runat="server"  MaxLength="10" Columns="15" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender11PJ" runat="server" TargetControlID="tbComplPJ" WatermarkText="Complemento do endereço" WatermarkCssClass="waterMark"/>
                                       </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Bairro:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbBairroPJ" runat="server"  MaxLength="45" Columns="80" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender12PJ" runat="server" TargetControlID="tbBairroPJ" WatermarkText="Seu bairro" WatermarkCssClass="waterMark"/>
                                            <asp:RequiredFieldValidator ControlToValidate="tbBairroPJ" 
                                               ErrorMessage="Favor informar o bairro." ID="rfvTbBairroPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender15PJ" runat="server" TargetControlID="rfvTbBairroPJ"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Cidade:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbCidPJ" runat="server"  MaxLength="45" Columns="80" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender13PJ" runat="server" TargetControlID="tbCidPJ" WatermarkText="Sua cidade" WatermarkCssClass="waterMark"/>
                                            <asp:RequiredFieldValidator ControlToValidate="tbCidPJ" 
                                               ErrorMessage="Favor informar sua cidade." ID="rfvTCidPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender16PJ" runat="server" TargetControlID="rfvTCidPJ"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Estado:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbUF2PJ" runat="server"  Columns="20" Enabled="false" ></asp:TextBox>
                                        </td>
                                        <td>
                                            CEP:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbCEPPJ" runat="server"  MaxLength="9" Columns="10" ></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender14PJ" runat="server" TargetControlID="tbCEPPJ" WatermarkText="Seu CEP" WatermarkCssClass="waterMark"/>
                                            <asp:MaskedEditExtender ID="MaskedEditExtender3PJ" runat="server" 
                                                ClearTextOnInvalid="True" ErrorTooltipEnabled="true" AutoComplete="False"
                                                ClearMaskOnLostFocus="true" 
                                                InputDirection="LeftToRight" Mask="99999-999" MaskType="None" 
                                                PromptCharacter="_" TargetControlID="tbCEPPJ" >
                                            </asp:MaskedEditExtender>
                                             <asp:RequiredFieldValidator ControlToValidate="tbCEPPJ" 
                                               ErrorMessage="Favor informar o cep." ID="rfvTbCEPPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar"></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender17PJ" runat="server" TargetControlID="rfvTbCEPPJ"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Telefone Comercial:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbFoneComlPJ" runat="server" MaxLength="15" Columns="44"></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender3PJ" runat="server" TargetControlID="tbFoneComlPJ" WatermarkText="Telefone comercial" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:MaskedEditExtender ID="MaskedEditExtender1PJ" runat="server" 
                                                ClearTextOnInvalid="True" ErrorTooltipEnabled="true" AutoComplete="False"
                                                ClearMaskOnLostFocus="true" 
                                                InputDirection="LeftToRight" Mask="(99) 999999999" MaskType="None" 
                                                PromptCharacter="_" TargetControlID="tbFoneComlPJ" >
                                            </asp:MaskedEditExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbFoneComlPJ" 
                                               ErrorMessage="Favor informar o n&uacute;mero de telefone da empresa." ID="rfvTbFoneComlPJ" Display="None"
                                               runat="server" ValidationGroup="Salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender4PJ" runat="server" TargetControlID="rfvTbFoneComlPJ"></asp:ValidatorCalloutExtender>
                                        </td>
                                    </tr>

                                    <tr>
                                        <td>
                                            Estado:
                                        </td>
                                        <td>
                                            <asp:DropDownList ID="ddlCadUF" runat="server" MaxLength="2">
                                            </asp:DropDownList>
                                            <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="*" 
                                            ControlToValidate="ddlCadUF" ValidationGroup="Salvar"></asp:RequiredFieldValidator>
                                        </td>

                                    <tr>
                                        <td>
                                            Nome de Usuário:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbUser" runat="server"  MaxLength="45" Columns="30" ToolTip="Este será o nome utilizado para acessar o carrinho de orçamentos no sistema"></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender4" runat="server" TargetControlID="tbUser" WatermarkText="Usuário para o carrinho de orçamentos" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbUser" 
                                               ErrorMessage="Favor informar um nome para o usuário." ID="rfvTbUser" Display="None"
                                               runat="server" ValidationGroup="salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender7" runat="server" TargetControlID="rfvTbUser"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Senha:
                                        </td>
                                        <td>
                                            <asp:TextBox ID="tbSenha" TextMode="Password" runat="server"  MaxLength="45" Columns="30" ToolTip="Este será a senha utilizada para acessar o carrinho de orçamentos no sistema"></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender5" runat="server" TargetControlID="tbSenha" WatermarkText="Senha para o carrinho de orçamentos" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbSenha" 
                                               ErrorMessage="Favor informar uma senha para o usuário." ID="rfvTbSenha" Display="None"
                                               runat="server" ValidationGroup="salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender21" runat="server" TargetControlID="rfvTbSenha"/>
                                        </td>
                                        <td colspan="2">
                                            pode conter letras ou números. (o sistema diferencia letras maiúsculas de minúsculas)
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Confirma&ccedil;&atilde;o de Senha:
                                        </td>
                                        <td colspan="3">
                                            <asp:TextBox ID="tbSenha2" TextMode="Password" runat="server"  MaxLength="45" Columns="30" ToolTip="Confirmação de senha, digite-a novamente exatamente como digitado acima."></asp:TextBox>
                                            <asp:TextBoxWatermarkExtender ID="TextBoxWatermarkExtender6" runat="server" TargetControlID="tbSenha2" WatermarkText="Confirmação da Senha para o carrinho de orçamentos" WatermarkCssClass="waterMark">
                                            </asp:TextBoxWatermarkExtender>
                                            <asp:RequiredFieldValidator ControlToValidate="tbSenha2" 
                                               ErrorMessage="Favor confirmar a senha para o usuário." ID="rfvTbSenha2" Display="None"
                                               runat="server" ValidationGroup="salvar" ></asp:RequiredFieldValidator>
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender22" runat="server" TargetControlID="rfvTbSenha2"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Mala direta?
                                        </td>
                                        <td colspan="3">
                                            <asp:RadioButtonList ID="rblMalaDireta" runat="server" RepeatDirection="Vertical">
                                                <asp:ListItem Text="Sim" Value="Sim"></asp:ListItem>
                                                <asp:ListItem Text="Não" Value="Nao"></asp:ListItem>
                                            </asp:RadioButtonList>
                                            <asp:RequiredFieldValidator ControlToValidate="rblMalaDireta" 
                                               ErrorMessage="Favor informar se gostaria de receber mala direta." ID="rfvRblMalaDireta" Display="None"
                                               runat="server" ValidationGroup="Salvar" />
                                            <asp:ValidatorCalloutExtender ID="ValidatorCalloutExtender6" runat="server" TargetControlID="rfvRblMalaDireta"/>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            Ativo:
                                        </td>
                                        <td colspan="3">
                                            <asp:CheckBox ID="ckbAtivo" runat="server" />
                                        </td>
                                    </tr>

                                    <tr>
                                        <td style="vertical-align:top;">
                                            Data Cadastro:
                                        </td>
                                        <td>
                                            <asp:Literal ID="ltDataCadastro" runat="server"></asp:Literal>
                                        </td>
                                        <td style="vertical-align:top;">
                                            Cadastrado por:
                                        </td>
                                        <td>
                                            <asp:Literal ID="ltCadastradoPor" runat="server"></asp:Literal>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td style="vertical-align:top;">
                                            Data Edi&ccedil;&atilde;o:
                                        </td>
                                        <td>
                                            <asp:Literal ID="ltDataEdicao" runat="server"></asp:Literal>
                                        </td>
                                        <td style="vertical-align:top;">
                                            Editado por:
                                        </td>
                                        <td>
                                            <asp:Literal ID="ltEditadoPor" runat="server"></asp:Literal>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td colspan="4">
                                            <span style="color:Red;"> (*) Campos Obrigatórios </span><br />
                                            <br />
                                            <br />
                                            <asp:Button ID="btnSalvar" runat="server" Enabled="False" ValidationGroup="Salvar"
                                                OnClick="btnSalvar_Click" Text="Salvar" />
                                            &nbsp;<asp:Button ID="btnCancelar" runat="server" OnClick="btnCancelar_Click" 
                                                Text="Cancelar" />
                                            <asp:Button ID="btnEditar" runat="server" Enabled="False" 
                                                OnClick="btnEditar_Click" Text="Editar" />
                                            &nbsp;<asp:Button ID="btnExcluir" runat="server" Enabled="False" 
                                                OnClick="btnExcluir_Click" Text="Excluir" />
                                            &nbsp;<asp:Button ID="btnNovo" runat="server" OnClick="btnNovo_Click" Text="Novo" />
                                            <asp:ConfirmButtonExtender ID="ConfirmButtonExtender1" runat="server" TargetControlID="btnExcluir" ConfirmText="Confirma a exclus&atilde;o do cliente? Aten&ccedil;&atilde;o! Todos os D&eacute;bitos e Documentos deste cliente ser&atilde;o permanentemente removidos!!!">
                                            </asp:ConfirmButtonExtender>
                                        </td>
                                    </tr>
                                </table>
                            </div>
                        </asp:Panel>
                    </ContentTemplate>
                </asp:TabPanel>
            </asp:TabContainer>
        </ContentTemplate>
    </asp:UpdatePanel>

                </div>
            </div>
        </div>
    </div>

</asp:Content>




